package com.java.module.user.domain.dto;

import javax.validation.constraints.NotBlank;

import com.java.common.lang.annotation.Encrypt;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

/**
 * 用户登录请求实体类
 * 
 * @author yilabao
 * @date 2021年2月3日
 */
@ApiModel(value = "登录请求")
@Encrypt
public class UserLoginDTO {

    /**
     * 用户名
     */
    @ApiModelProperty(value = "用户名", required = true, position = 1)
    @NotBlank(message = "用户名不能为空")
    private String username;

    /**
     * 用户密码
     */
    @ApiModelProperty(value = "登录密码（RSA加密）", required = true, position = 2)
    @NotBlank(message = "密码不能为空")
    @Encrypt
    private String password;

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    @Override
    public String toString() {
        return "UserLoginDTO [username=" + username + ", password=" + password + "]";
    }

}